﻿<head>

	<title>管理员页面</title>
	<script src="../js/jquery-3.2.1.min.js"></script>
		<!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
	<link rel="stylesheet" href="../css/bootstrap.min.css" >	
	<!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
	<script src="../js/bootstrap.min.js" ></script>
	<link rel="stylesheet" type="text/css" href="../css/index.css">
</head>
<body>
	<div>
	<nav class="navbar navbar-default navbar-fixed-top top" >
		<a href="../"><img class="top_left" src="../images/log.png"></a>
		<div class="pull-right" style="margin-top: 15px;margin-right: 20px;">
			<a href="http://www.xinli001.com/ceshi">关于心理测试</a>
	
		</div>
		</nav>
	</div>	
	<br/><br/>
	<h1>管理问题：</h1>
	<hr /> 
	
	
<?php
mysql_connect("localhost","root","root");//
mysql_query("set names utf8"); 
$query="select * from question";
$result = mysql_db_query("psychology","$query");
$data = mysql_fetch_object($result);

echo "<table border='1px solide black'>";
echo "<tr><td>questionPart</td><td>answerA</td><td>answerB</td><td>answerC</td><td>answerD</td><td>operate1</td><td>operate2</td></tr>";
while ($data = mysql_fetch_object($result)) {
echo "<tr><td>".$data->questionPart."</td><td>".$data->answerA."</td><td>".$data->answerB."</td><td>".$data->answerC."</td><td>".$data->answerD."</td><td><a href='questionEdit2.php?questionID=".$data->questionID."'>修改</a></td><td><a href='questionDelete.php?questionID=".$data->questionID."'>删除</a></td></tr>";
}
?>
<a href="questionInsert.php">插入</a>


<hr />
<?php
mysql_connect("localhost","root","root");//
mysql_query("set names utf8"); 
$query="select * from result";
$result = mysql_db_query("psychology","$query");
$data = mysql_fetch_object($result);

echo "<table border='1px solide black'>";
echo "<tr><td>resultPart</td><td>resultA</td><td>resultB</td><td>resultC</td><td>resultD</td><td>operate1</td><td>operate2</td></tr>";
while ($data = mysql_fetch_object($result)) {
echo "<tr><td>".$data->resultPart."</td><td>".$data->resultA."</td><td>".$data->resultB."</td><td>".$data->resultC."</td><td>".$data->resultD."</td><td><a href='resultEdit2.php?resultID=".$data->resultID."'>修改</a></td><td><a href='resultDelete.php?resultID=".$data->resultID."'>删除</a></td></tr>";
}
?>

<h1>管理结果</h1>
<hr>
<a href="resultInsert.php">插入</a>

</body>
